/*
 * @FilePath: /vue3-ts-h5-template/mock/list.mock.ts
 */
import { defineMock } from 'vite-plugin-mock-dev-server';
import Mock from 'mockjs';

export default defineMock([
  {
    url: '/dev-api/list/get',
    delay: 1000,
    body: {
      code: 0,
      message: 'OK',
      data: Mock.mock({
        'list|10': [
          {
            'id|+1': 1,
            name: '@cname',
            'age|1-100': 1,
            email: '@email',
            address: '@county(true)',
            phone: /^1[34578]\d{9}$/
          }
        ],
        total: 10
      })
    }
  }
]);
